package org.gap.domain;

import java.io.Serializable;

import javax.persistence.Id;

import javax.persistence.*;

/**
 */
public class GuichetsPK implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 */
	public GuichetsPK() {
	}

	/**
	 */

	@Column(name = "GUI_ETABLISSEMENT", nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@Id
	public Integer guiEtablissement;
	/**
	 */

	@Column(name = "GUI_GUICHET", nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@Id
	public Integer guiGuichet;
	/**
	 */

	@Column(name = "GUI_PAYS", length = 3, nullable = false)
	@Basic(fetch = FetchType.EAGER)
	@Id
	public String guiPays;

	/**
	 */
	public void setGuiEtablissement(Integer guiEtablissement) {
		this.guiEtablissement = guiEtablissement;
	}

	/**
	 */
	public Integer getGuiEtablissement() {
		return this.guiEtablissement;
	}

	/**
	 */
	public void setGuiGuichet(Integer guiGuichet) {
		this.guiGuichet = guiGuichet;
	}

	/**
	 */
	public Integer getGuiGuichet() {
		return this.guiGuichet;
	}

	/**
	 */
	public void setGuiPays(String guiPays) {
		this.guiPays = guiPays;
	}

	/**
	 */
	public String getGuiPays() {
		return this.guiPays;
	}

	/**
	 */
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = (int) (prime * result + ((guiEtablissement == null) ? 0 : guiEtablissement.hashCode()));
		result = (int) (prime * result + ((guiGuichet == null) ? 0 : guiGuichet.hashCode()));
		result = (int) (prime * result + ((guiPays == null) ? 0 : guiPays.hashCode()));
		return result;
	}

	/**
	 */
	public boolean equals(Object obj) {
		if (obj == this)
			return true;
		if (!(obj instanceof GuichetsPK))
			return false;
		GuichetsPK equalCheck = (GuichetsPK) obj;
		if ((guiEtablissement == null && equalCheck.guiEtablissement != null) || (guiEtablissement != null && equalCheck.guiEtablissement == null))
			return false;
		if (guiEtablissement != null && !guiEtablissement.equals(equalCheck.guiEtablissement))
			return false;
		if ((guiGuichet == null && equalCheck.guiGuichet != null) || (guiGuichet != null && equalCheck.guiGuichet == null))
			return false;
		if (guiGuichet != null && !guiGuichet.equals(equalCheck.guiGuichet))
			return false;
		if ((guiPays == null && equalCheck.guiPays != null) || (guiPays != null && equalCheck.guiPays == null))
			return false;
		if (guiPays != null && !guiPays.equals(equalCheck.guiPays))
			return false;
		return true;
	}

	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder("GuichetsPK");
		sb.append(" guiEtablissement: ").append(getGuiEtablissement());
		sb.append(" guiGuichet: ").append(getGuiGuichet());
		sb.append(" guiPays: ").append(getGuiPays());
		return sb.toString();
	}
}
